Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

refactor: Remove Item from merger's Node trait #3371

Merged
merged 8 commits into from
Feb 24, 2024

Conversation

evenyag
Copy link
Contributor

@evenyag evenyag commented Feb 23, 2024

I hereby agree to the terms of the GreptimeDB CLA

What's changed and what's your intention?

This PR removes the associated type Item from the Node trait of the merger mod. It is helpful to support ?Size item of a node.

Now the DataBatch is a slice of the referencing RecordBatch.

  • It doesn't own the RecordBatch.
  • It should only access the range of the RecordBatch.
  • DataBatchRange maintains the range of a DataBatch.

This avoids slicing the RecordBatch via RecordBatch::slice().

Checklist

  • I have written the necessary rustdoc comments.
  • I have added the necessary unit tests and integration tests.
  • This PR does not require documentation updates.

Refer to a related PR or issue link (optional)

@github-actions github-actions bot added the docs-not-required This change does not impact docs. label Feb 23, 2024
@evenyag evenyag marked this pull request as ready for review February 24, 2024 05:57
Copy link
Collaborator

@fengjiachun fengjiachun left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

Copy link

codecov bot commented Feb 24, 2024

Codecov Report

Attention: Patch coverage is 85.40773% with 34 lines in your changes are missing coverage. Please review.

Project coverage is 85.18%. Comparing base (1f1d1b4) to head (c8747e3).
Report is 1 commits behind head on main.

❗ Current head c8747e3 differs from pull request most recent head 0238ccd. Consider uploading reports for the commit 0238ccd to get more accurate results

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #3371      +/-   ##
==========================================
- Coverage   85.58%   85.18%   -0.41%     
==========================================
  Files         892      892              
  Lines      146543   146572      +29     
==========================================
- Hits       125413   124851     -562     
- Misses      21130    21721     +591     

Copy link
Contributor

@v0y4g3r v0y4g3r left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@evenyag evenyag enabled auto-merge February 24, 2024 07:09
@evenyag evenyag added this pull request to the merge queue Feb 24, 2024
Merged via the queue into GreptimeTeam:main with commit 1df64f2 Feb 24, 2024
16 checks passed
@evenyag evenyag deleted the refactor/merger branch February 24, 2024 07:34
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
docs-not-required This change does not impact docs.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants